package com.zzyl.mapper;

import com.github.pagehelper.Page;
import com.zzyl.dto.VisitDto;
import com.zzyl.entity.Visit;
import com.zzyl.vo.VisitVo;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.time.LocalDateTime;
import java.util.List;

@Mapper
public interface VisitMapper {

    int update(Visit visit);

    int deleteById(Long id);

    Visit findById(Long id);

    List<Visit> findAll(@Param("mobile") String mobile, @Param("startTime") LocalDateTime startTime, @Param("endTime") LocalDateTime endTime);

    void add(Visit visit);

    Page<VisitVo> findByPage(Long userId, String name, String mobile, Integer status, Integer type, LocalDateTime startTime, LocalDateTime endTime);


}
